<!DOCTYPE HTML>
<html  lang="zh" xmlns:th="http://www.thymeleaf.org">
<meta charset="utf-8">
<head th:include="include :: header"></head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-wdyWithdraw-edit" th:object="${wdyWithdraw}">
            <input id="id" name="id" th:field="*{id}"  type="hidden">
			<input id="withdrawStatus" name="withdrawStatus" th:field="*{withdrawStatus}" class="form-control" type="hidden">
			<div class="form-group">	
				<label class="col-sm-3 control-label">提币订单号：</label>
				<div class="col-sm-8">
					<input id="withdrawId" name="withdrawId" th:field="*{withdrawId}" class="form-control" type="text" readonly>
				</div>
			</div>
			<div class="form-group">	
				<label class="col-sm-3 control-label">用户id：</label>
				<div class="col-sm-8">
					<input id="userId" name="userId" th:field="*{userId}" class="form-control" type="text" readonly>
				</div>
			</div>
			<div class="form-group">	
				<label class="col-sm-3 control-label">提币金额：</label>
				<div class="col-sm-8">
					<input id="amount" name="amount" th:field="*{amount}" class="form-control" type="text" readonly>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">金额类型：</label>
				<div class="col-sm-8">
					<select name="amountType" class="form-control m-b" th:with="type=${@dict.getType('wdy_amount_type')}">
						<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{amountType}"></option>
					</select>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">提币地址：</label>
				<div class="col-sm-8">
					<input id="walletAddress" name="walletAddress" th:field="*{walletAddress}" class="form-control" type="text" readonly>
				</div>
			</div>
			<div class="form-group">	
				<label class="col-sm-3 control-label">提币发起时间：</label>
				<div class="col-sm-8">
					<input id="withdrawTime" name="withdrawTime" th:value="*{#dates.format(withdrawTime, 'yyyy-MM-dd HH:mm:ss')}" class="form-control" type="text" readonly>
				</div>
			</div>
		</form>
    </div>
	<div class="row">
		<div class="col-sm-offset-5 col-sm-10">
			<button type="button" class="btn btn-sm btn-primary" onclick="withdrawConfirm(true)"><i class="fa fa-check"></i>通过</button>&nbsp;
			<button type="button" class="btn btn-sm btn-danger" onclick="withdrawConfirm(false)"><i class="fa fa-close"></i>不通过</button>&nbsp;
			<button type="button" class="btn btn-sm btn-success" onclick="closeItem()"><i class="fa fa-reply-all"></i>关 闭 </button>
		</div>
	</div>
    <div th:include="include::footer"></div>
    <script type="text/javascript">
		var prefix = ctx + "system/wdyWithdraw";
		function withdrawConfirm(pass) {
		    var msg = pass ? "确认通过吗？" : "确认不通过吗？"
            $.modal.confirm(msg, function() {
				$('#withdrawStatus').val(pass ? 1 : 2);
                $.operate.saveTab(prefix + "/confirm", $('#form-wdyWithdraw-edit').serialize());
            })
	    }
	</script>
</body>
</html>
